package day04_Array;
//遍历:获取数组中的元素个数
//格式:数组名称.length
//遍历数组的通用格式:int [] arr={........}; for(inti=0;i<arr.length-1;i++){System.out.println(arr[i])}
public class Demo10_Array {
    public static void main(String[] args) {
        int [] array=new int[]{1,5,6,7,9,3,2};
        for (int i = 0; i < array.length; i++) {
            System.out.println(array[i]);
        }
    }
}
